#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
#include<stdlib.h>

int main() {
    int x = 0;
    int k = 0;
    int s = 0;
    scanf("%d", &x);
    int* arr = (int*)malloc(x * sizeof(int));
    for (int i = 0; i < x; i++) {
        scanf("%d", &arr[i]);
    }
    scanf("%d%d", &k, &s);
    int left = 0;
    int right = x - 1;
    while (left <= right) {
        int mid = (left + right) / 2;
        if (arr[mid] < (s - k)) {
            left = mid + 1;
        }
        else if (arr[mid] > (s - k)) {
            right = mid - 1;
        }
        else if (arr[mid] == (s - k)) {
            printf("Yes");
            free(arr);
            return 0;
        }
    }
    printf("No");
    free(arr);
    return 0;
}
